Data processing systems, methods and computer program products that use the 3270 datastream architecture have been widely used for decades. The 3270 datastream architecture has been so widely used, that systems using the 3270 datastream architecture are often referred to as "legacy" systems.
The 3270 datastream architecture is used to communicate between a Primary Logical Unit (PLU) and a Secondary Logical Unit (SLU) using LU2 protocol. It will be understood that the primary and secondary logical units may be mainframe computers, midrange computers, personal computers, terminals, workstations or one or more computer programs that execute on one or more of the above. The 3270 datastream architecture is described in many publications, including but not limited to the "IBM 3270 Information Display System Datastream Programmer's Reference", published by International Business Machines Corporation (IBM), the assignee of the present application, IBM Publication Number GA23-0059-07, 1982, the disclosure of which is hereby incorporated herein by reference.
As shown in FIG. 1, a data processing system 100 includes a PLU 110 and an SLU 120 that communicate with each other over a network 130 using the 3270 datastream. The PLU 110 may also be referred to as a host or server, and the SLU 120 may be referred to as a terminal, workstation, emulator or client. It will be understood that, although FIG. 1 illustrates a simple data processing system 100 including one PLU 110, one SLU 120 and a simple network connection 130, the 3270 datastream architecture is generally used to communicate among many PLUs and SLUs using complex network environments. An example of a more typical data processing system using 3270 datastream architecture may be found in U.S. Pat. No. 5,649,101, entitled "System and Method for Improving 3270 Data Stream Performance by Reducing Transmission Traffic" to Mathewson II, assigned to the assignee of the present invention, the disclosure of which is hereby incorporated herein by reference.
The 3270 datastream architecture was designed before graphical user interfaces (GUI) became commonplace. Because of the ease of use that a graphical user interface may provide, it is desirable to provide graphical user interfaces for 3270 datastream architecture systems. However, due to the legacy nature of 3270 datastream architecture systems, it is generally desirable to provide graphical user interfaces without requiring rewriting of legacy code or rearchitecting of legacy systems.
One widely used programming language that can provide a rich graphical user interface is Java As is well known to those having skill in the art, Java programs, in compiled form, are generally portable and will generally run on a wide range of computers and operating systems. Stated differently, Java provides a machine-dependent desktop for executing machine independent applications and applets. Java programs support referencing Universal Resource Locator (URL) identifiers with content types of, for example, audio/basic, audio/x-WAV image/GIF and image/JPEG.
Accordingly, it would be desirable to integrate Java with legacy 3270 applications to obtain the advantages of Java as a portable programming language and the potential cost-savings of Java's centralized application distribution paradigm. However, it would be desirable to integrate Java with legacy 3270 applications without the need to write new legacy applications or to modify existing legacy applications.
Many techniques exist for integrating Java with legacy 3270 applications. These techniques include screen-scraping, an HTML gateway, an object request broker and loading Java classes over LU2 and LU6.2. However, each of these techniques may have shortcomings as described below.
Screen-scraping is a technique of interacting programmatically with the 3270 datastream at the client, in order to combine host data from one or more sources with new program logic and a graphical user interface. The client application gains access to the 3270 data through an application programming interface on a terminal emulator. This program can read the screen contents, issue keystrokes and perform all the other actions that a user could perform. Unfortunately, although it may offer a cosmetic improvement compared to a standard 3270 screen, the screen-scraping application may be vulnerable to a positional change in the host data, such as a date change that shifts data to a new screen offset. Moreover, screen-scraping may also require distributing the application, and subsequent updates to it, to all clients. This problem may be partly overcome by writing the screen-scraper application in Java, if a TCP/IP network is available over which the Java application could be distributed, but this may not automatically confer all of Java's benefits. The client application may still need to be distributed to all the client workstations, or may need to be stored on a separate web server, if having a parallel infrastructure is acceptable. In a large enterprise, however, it may take years to make such a sweeping network change, with all the accompanying administrative hardware and software changes.
A hypertext mark-up language (HTML) gateway is a more general extension of screen-scraping. An HTML gateway is a separate program between a host application and a 3270 emulator. The HTML gateway can convert the entire 3270 datastream to HTML. The client then becomes a browser. An HTML gateway may reproduce the visual appearance of a 3270 screen, or it may interpret the data and convert it into a new graphical user interface representation. It is even possible to read-in the 3270 screen maps residing on the host that are used to format data extracted from a database for 3270 presentation, interpret them and use this augmented information to generate a more tailored HTML screen. Existing products, such as VisualAge for Small Talk Version 3.0 interact with these Basic Mapping Support (BMS) or Message Format Service (MFS) maps.
Unfortunately, HTML gateways may have drawbacks because host applications generally cannot handle unexpected navigational sequences. Thus, if a user presses the browser's Back button to display a previous screen, and then presses a key, causing input to the host application, the application state may not match the data. This could cause a program crash or an undetected logic error that puts incorrect data into a database. Moreover, if the secondary logical unit is at an intermediate gateway rather than at the client, it may be difficult to diagnose faults that occur between-the gateway and the client, or to correlate faults at the gateway with the session between the host and the gateway.
Object Request Brokers may be used to replace 3270 datastream communications with object-oriented remote procedure calls. Thus, access to legacy data and legacy applications may be provided by wrapping them in an object wrapper. An Object Request Broker is an example of an object wrapper. Unfortunately, this approach may require monolithic new software development. It may not lend itself to incremental replacement of legacy applications. However, with the large amount of legacy application code that is present, it may not be feasible to replace these applications monolithically. Moreover, remote method invocations and remote procedure calls may not be optimized for the delays and limited bandwidth that are typical of a wide area network, so that performance may be unsatisfactory or degraded.
Finally, Java classes may be loaded by a modified Java class loader that uses LU2 and LU6.2 sessions as its transport. By typing a command on a host command line, a user can invoke the Systems Network Architecture (SNA) for Java class loader. However, this may not integrate Java with the 3270 datastream.
The above survey indicates that although it is generally desirable to integrate Java with legacy 3270 applications, there may be shortcomings with conventional techniques for doing so. Accordingly, there continues to be a need for systems, methods and computer program products for passing Java bytecodes between a primary logical unit and a secondary logical unit that communicate with each other over a network using 3270 datastream architecture.
The 3270 datastream architecture communications between a PLU and a SLU generally take place in a manner that is quite different from communications using Java. More specifically, communications between a primary logical unit and a secondary logical take place using LU2 protocol.
As is well known to those having skill in the art, the LU2 protocol is half-duplex flip-flop (two-way alternating) protocol. A sender sets a Change Direction indicator when it has finished a transmission, and expects the next transmission to be from the receiver. Brackets delineate a series of Request/Response Units (RUs) that together provide a single transaction. Between brackets, either the PLU or the SLU may begin a new bracket. In the case of bracket contention, the SLU has priority. Only the PLU can end a bracket. Chaining allows multiple RUs to be sent in a group to the same LU. When a definite response or exception response is requested, a chain is the unit that the LU acknowledges or rejects. LU2 protocol is described in many publications, including but not limited to the "IBM 3174 Establishment Controller Functional Description", published by International Business Machines Corporation (IBM), the assignee of the present application, IBM Publication No. GA23-0218-11, 1994, the disclosure of which is hereby incorporated herein by reference.
In contrast, Java programs (applets) generally are dynamically downloaded from a web server. Java applets are generally invoked from a web browser by an "applet" tag embedded in HyperText Mark-up Language (HTML). Java generally operates on an Internet Protocol (IP) network.
Notwithstanding these differences, it would be desirable to pass Java bytecodes between a first Java Virtual Machine (JVM) in a PLU and second JVM in an SLU that communicate with each other over a network using 3270 datastream architecture. Such communications should preferably take place asynchronously, and the Java bytecode communications should not significantly impact conventional 3270 datastream communications.